package Java攻略._3_流式操作._1_流的创建;

import java.util.stream.Collectors;
import java.util.stream.Stream;

public class _2_利用Stream_of方法创建流 {

    public static void main(String[] args) {

        String names = Stream.of("Gomez", "Morticia", "Wednesday", "Pugsley")
                .collect(Collectors.joining(", "));
        System.out.println(names);
    }
}
